<template>
  <j-modal
    :title="title"
    :width="width"
    :visible="visible"
    switchFullscreen
    :footer="null"
    @cancel="visible=false">
    <a-card :bordered="false">
      <div>
        <a-table
          ref="table"
          size="middle"
          :scroll="{x:true}"
          bordered
          rowKey="id"
          :columns="columns"
          :dataSource="dataSource"
          :pagination="ipagination"
          @change="handleTableChange"
          :loading="loading"
          class="j-table-force-nowrap">
        </a-table>
      </div>
    </a-card>
  </j-modal>
</template>

<script>

  import '@/assets/less/TableExpand.less'
  import { mixinDevice } from '@/utils/mixin'
  import { JeecgListMixin } from '@/mixins/JeecgListMixin'
  import VcaFarmlandRentModal from './modules/VcaFarmlandRentModal'

  export default {
    name: 'VcaFarmlandContractList',
    mixins:[JeecgListMixin, mixinDevice],
    components: {},
    data () {
      return {
        visible:false,
        disableMixinCreated:true,
        width:600,
        title:'',
        description: 'vca_farmland_rent管理页面',
        columns: [
          {
            title: '#',
            dataIndex: '',
            key:'rowIndex',
            width:60,
            align:"center",
            customRender:function (t,r,index) {
              return parseInt(index)+1;
            }
          },
          {
            title:'所有者',
            align:"center",
            dataIndex: 'ownName',
          },
          {
            title:'出租面积',
            align:"center",
            dataIndex: 'rentArea'
          }
        ],
        url: {
          list: "/villageCadreAssist/vcaFarmlandRent/list"
        }
      }
    },
    methods: {
      initDictConfig(){
      },
      view(record){
        this.model = Object.assign({},record)
        this.queryParam.rentId = record["id"];
        this.loadData();
        this.visible=true;
      }
    }
  }
</script>
<style scoped>
  @import '~@assets/less/common.less';
</style>